<template>
  <div>
    <h3>自定义事件</h3>
    <div>
      <Child :count="count" @add="add" />
    </div>
  </div>
</template>

<script>
import Child from "./Child.vue";
export default {
  name: "Customize",
  components: { Child },
  data() {
    return {
      count: 0,
    };
  },
  methods: {
    add(value) {
      // console.log(this.$event);
      this.count += value;
    },
  },
};
</script>

<style>
</style>